Add parse function to Rust RBS bindings#53
Merged
alexcrocha merged 1 commit intoar-rust-rbs-buildfrom Oct 28, 2025
Merged
Conversation
Merged
Author
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
alexcrocha
commented
Oct 24, 2025
vinistock
reviewed
Oct 27, 2025
rust/ruby-rbs/src/lib.rs
Outdated
| } | ||
|
|
||
| #[test] | ||
| fn test_rbs_string_new() { |
Member
There was a problem hiding this comment.
I'm wondering if we need this test or if we should keep all of our testing at the parser integration level. My gut feeling is that we could just test all of our Rust structures through the result of parsing RBS code and avoid manually instantiating anything.
What do you think? Do you think we lose any guarantees if we test everything through the parser?
c0cf31d to
a6b528d
Compare
91a4364 to
2320c10
Compare
This was referenced Oct 28, 2025
Closed
Implement the parse function that enables parsing RBS code from Rust. This provides a safe Rust interface to the C parser, handling memory management and encoding setup.
2320c10 to
734389f
Compare
vinistock
approved these changes
Oct 28, 2025
This was referenced Nov 18, 2025
Merged
Merged
Merged
This was referenced Nov 25, 2025
Merged
This was referenced Dec 9, 2025
Merged
This was referenced Dec 18, 2025
alexcrocha
added a commit
that referenced
this pull request
Jan 13, 2026
The `parse` function enables parsing RBS code from Rust. This provides a safe Rust interface to the C parser, handling memory management and encoding setup.
alexcrocha
added a commit
that referenced
this pull request
Jan 13, 2026
The `parse` function enables parsing RBS code from Rust. This provides a safe Rust interface to the C parser, handling memory management and encoding setup.
This was referenced Jan 13, 2026
Merged
Merged
alexcrocha
added a commit
that referenced
this pull request
Jan 14, 2026
The `parse` function enables parsing RBS code from Rust. This provides a safe Rust interface to the C parser, handling memory management and encoding setup.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

This PR originally was testing
RBSStringby manually instantiating it and verifying its methods. Now it adds aparsefunction that enables testing our Rust structures through the parser integration level, following the review feedback that parser integration tests will cover everything we need without requiring separate unit tests.The
parsefunction provides a safe Rust interface to the C parser. While we can't yet access parsed AST fields to fully verify string translation (requires more bindings), this establishes the foundation for parser-based testing going forward.